<!DOCTYPE html>
<html lang="cmn-Hans">
  <head>
    <title>扩容_融易找房</title>
    <meta charset="utf-8">
    <meta http-equiv="x-rim-auto-match" content="none">
    <meta http-equiv="Cache-Control" content="no-transform">
    <meta http-equiv="X-UA-Compatible" content="IE=edge, chrome=1">
    <meta name="keywords" content="">
    <meta name="description" content="">
    <meta name="renderer" content="webkit">
    <meta name="format-detection" content="telephone=no, email=no">
    <meta name="full-screen" content="yes">
    <meta name="x5-fullscreen" content="true">
    <meta name="apple-touch-fullscreen" content="yes">
    <meta name="applicable-device" content="mobile">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <link rel="canonical" href="{$url}">
    <link rel="stylesheet" href="__STATIC__/css/base.css">
    <link rel="stylesheet" href="__STATIC__/css/ezuser.css">
    <script src="__STATIC__/js/jquery-1.9.1.min.js"></script>
    <link rel="stylesheet" href="__STATIC__/font/iconfont.css">
  </head>
  <body id="app">
    <div class="g-page g-page-dark">
      <header class="g-hd g-hd-title">
        <div class="m-hd m-hd-title f-tac">
          <div class="func func-l f-fl"><a class="back icon icon-arrl" href="javascript:history.back(-1);"></a></div>
          <div class="title">续费会员</div>
        </div>
      </header>
      <div class="g-bd">
        <div class="m-card m-card-dvip">
          <div class="dvip"><i class="ico ico-dvip"></i>
            <div class="time">{$user_info.user_name}
              <div class="sub">有效期至  {$user_info.expiration_time_text}</div>
            </div><span class="u-btn">{$user_info.port}个端口</span>
          </div>
        </div>
        <div class="m-form">
        
            <div class="group group-cardfull">
              <div class="head">扩容</div>
              <div class="item item-pay">
                <label class="lab lab-pay">楼盘端口<span class="sub">到期时间</span></label>
                <div class="flex">
                  <div class="moms"><span>&yen;<em>{$day_price}</em></span>
                    <div class="sub">{$user_info.expiration_time_text}</div>
                  </div>
                  <div class="stepper">
                    <button class="u-btn" type="button" data-type="minus" disabled><i class="icon icon-del"></i></button>
                    <input class="u-ipt" type="text" value="1" disabled="disabled">
                    <button class="u-btn" type="button" data-type="plus"><i class="icon icon-add"></i></button>
                  </div>
                </div>
              </div>
            </div>
            <div class="group group-fixs">
              <div class="item item-smt">
                <div class="momey">总计&emsp;&yen;<em>{$day_price}</em></div>
                <button class="u-smt" type="submit">付款</button>
              </div>
            </div>
			
        </div>
      </div>
    </div>
    <script src="__STATIC__/layui/layui.js"></script>
    <script src="http://res2.wx.qq.com/open/js/jweixin-1.6.0.js"></script>
	
    <script>
      layui.use(['layer'], function(){
        $('.stepper').on('click', '.u-btn', function(){
          var ipt = $(this).siblings('.u-ipt');
          var val = ipt.val();
          
          $(this).data('type') == 'plus' ? ++val : --val;
          if(val < 2){
            ipt.val(1).prev().prop('disabled', 'disabled');
            $('.group-fixs .momey em').text({$day_price});
          }else{
            ipt.val(val).prev().prop('disabled', false);
            $('.group-fixs .momey em').text(val*{$day_price});
          }
        });
		
		
		$('[class=u-smt]').click(function(){
			var num = $('.u-ipt').val();
			
			<!-- $.post("distPayAddSubmit",{num:num},function(result){ -->
				<!-- alert(result.msg); -->
				<!-- if(result.code == 1){ -->
					<!-- wx.chooseWXPay({ -->
					  <!-- timestamp: "{$jssdk.timestamp}", -->
					  <!-- nonceStr: "{$jssdk.nonceStr}",  -->
					  <!-- package: 'prepay_id='+result.prepay_id, -->
					  <!-- signType: 'SHA1',  -->
					  <!-- paySign: "{$jssdk.signature}", -->
					  <!-- success: function (res) { -->
						<!-- window.location.href = "distPaySubmit"; -->
					  <!-- } -->
					<!-- }); -->
				<!-- } -->
		  <!-- }); -->
		  
		  $.post("distPayAddSubmit",{num:num},function(result){
				alert(result.msg);
				if(result.code == 1){
					window.location.href = "distPaySubmit";
				}
		  });
		  
        });
		
		
      });
    </script>
  </body>
</html>